﻿namespace FFF.Test.Application.Repositories.FW
{
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using Abp.Domain.Repositories;
    using Abp.EntityFrameworkCore;
    using Abp.ObjectMapping;
    using FFF.Test.DataAccess.Framework;
    using FFF.Test.Application.Repositories.FW;
    using FFF.Test.Entity.FW;
    using FFF.Test.Entity.FW.Dto;
    using FFF.Test.Entity.FW.View;
    using FFF.Test.Application.PublicService.AppService.TreeGrid;

    /// <summary>
    /// 公司组织表(树)仓储接口
    /// </summary>
    public interface IFWBuUnitRepository : 
        IRepository<FWBuUnitEntity, 
        Guid>, IRepositoriesBase<FWBuUnitEntity, Guid, FWBuUnitCreateInputDto, FWBuUnitUpdateInputDto, FWBuUnitDto, ViewFWBuUnit, ViewFWBuUnit>
    {
        /// <summary>
        ///  获取树形列表(框架生成)
        /// </summary>
        /// <param name="pid">父级id</param>
        /// <returns>获取树形列表输出dto</returns>
        Task<List<TreeGridOutDto>> GetTreeGirdAsync(Guid? pid);

        /// <summary>
        ///  获取所有的父级的id 以,分割(框架生成)
        /// </summary>
        /// <param name="id">父级id</param>
        /// <returns>父级的id以,分割</returns>
        Task<string> GetFatherIdsAsync(Guid id);
    }
}
